<!DOCTYPE html>
<html lang="zh">
<head>
    {{template "header" (ossUrl)}}
    <link href="/resource/ajax/libs/select2/select2.min.css" rel="stylesheet"/>
    <link href="/resource/ajax/libs/select2/select2-bootstrap.css" rel="stylesheet"/>
    <link href="/resource/ajax/libs/bootstrap-select/bootstrap-select.css" rel="stylesheet"/>
</head>
<body class="gray-bg">
<div class="container-div">
    <form id="updatemysql">
        <div class="col-sm-6">
            <div class="ibox float-e-margins">
                <div class="ibox-title">
                    <h5>选择数据库备份</h5>
                </div>
                <div class="ibox-content">
                    <div class="form-group">
                        <label class="font-noraml">单选</label>
                        <select class="form-control" name="filepath">
                            <option value="">--请选择备份--</option>
                            {{range $key, $value := .files}}
                                <option value="{{$value.Filepath}}">{{$value.Filename}}</option>
                            {{end}}
                        </select>
                    </div>
                </div>
            </div>
        </div>
    </form>
</div>
{{template "footer" (ossUrl)}}
<script src="/resource/ajax/libs/select2/select2.min.js"></script>
<script src="/resource/ajax/libs/bootstrap-select/bootstrap-select.js"></script>
<script type="text/javascript">
    var prefix = ctx + "tool/gen";

    /* 导入表结构-选择表结构-提交 */
    function submitHandler() {
        if ($.validate.form()) {
            $.operate.save(prefix + "/updatemysql", $('#updatemysql').serialize());
        }
    }
</script>
</body>
</html>